package datenbank;

import java.sql.Connection;
import java.sql.SQLException;
import java.sql.Statement;

/**
 * 
 * 
 * 
 * @date 21.08.2012
 * @author rs
 * @version 1.0
 * 
 */
public class into {

	/**
	 * 
	 * 
	 * @param st
	 * @param conn
	 * @param tabelle
	 * @param spalte
	 * @param wert
	 * @throws SQLException
	 */
	public static synchronized void schreibenSpalte(Statement st, Connection conn, String tabelle, String spalte, String wert)
			throws SQLException {

		st = conn.createStatement(); // statements

		int i = st.executeUpdate("INSERT INTO " + tabelle + "(" + spalte + ") VALUES " + "('" + wert + "')");

		if (i == -1) {
			System.out.println("db error : " + tabelle);
		}

		st.close();
	} // void update()
}
